#ifndef _BlockManager
#define _BlockManager

#include "Block.h"

class BlockManager {
public:
	Block *head;

	// Constructor
	BlockManager();
	// Deconstrucor
	~BlockManager();

	// Manage a new block
	bool add(char* /*index*/, int /*size*/);
	// Delete a block
	bool del(Block*);

	// returns total number of todos in 'pending' state
	int getPending();
	// returns total number of todos in 'active' state
	int getActive();
	// returns total number of todos in 'complete' state
	int getComplete();

	// a thread is started, keep a tally
	void thread_start();

	// a thread is complete, keep a tally
	void thread_complete();
	
	// whether block is complete
	bool isComplete();

	// returns the next index to start
//	char* getNextIndex();

	// track the todo thread
//	bool track(HANDLE todo);

	// updates the status of todos
//	void update();

	// Find an active thread and watch it waiting for it to finish, return true
	// If unable to find an active thread, return false
//	bool waitForThread();
};

#endif // _BlockManager